package com.rws.monitoring;

import java.util.concurrent.locks.Lock;

public interface ControlMonitor {
    /**
     * 向锁监听器中注册实例
     * @param lock 锁对象
     * @param currentThread 被锁的线程，一般是Thread.currentThread()
     */
    void register(Lock lock, Thread currentThread);

    /**
     * 向锁监听器中注销实例
     * @param lock 锁对象
     * @param currentThread 被锁的线程，一般是Thread.currentThread()
     */
    void release(Lock lock, Thread currentThread);
}
